package com.shfl.task.pagehelper;


public class PageableUtil {

    private PageableUtil() {
    }

    /**
     * 获取分页
     * @param pageNo 分页数
     * @param pageSize 分页大小
     * @return  分页
     */
    public static Pageable getPageable(Integer pageNo, Integer pageSize) {
        if (pageNo == null) {
            pageNo = 1;
        }
        if (pageSize == null) {
            pageSize = 10;
        }
        Pageable pageable = new Pageable();
        pageable.setPageNo(pageNo);
        pageable.setPageSize(pageSize);
        return pageable;
    }


}
